
<!DOCTYPE HTML>
<html lang="" >
    <head>
        <meta charset="UTF-8">
        <meta content="text/html; charset=utf-8" http-equiv="Content-Type">
        <title>3.5 动手 - 修改更多CSS样式 · Girls Coding Day Tutorial</title>
        <meta http-equiv="X-UA-Compatible" content="IE=edge" />
        <meta name="description" content="">
        <meta name="generator" content="GitBook 3.2.3">
        <meta name="author" content="Yang Wen <wenyang@codingirls.club>">
        
        
    
    <link rel="stylesheet" href="../gitbook/style.css">

    
            
                
                <link rel="stylesheet" href="../gitbook/gitbook-plugin-highlight/website.css">
                
            
                
                <link rel="stylesheet" href="../gitbook/gitbook-plugin-search/search.css">
                
            
                
                <link rel="stylesheet" href="../gitbook/gitbook-plugin-fontsettings/website.css">
                
            
        

    

    
        
    
        
    
        
    
        
    
        
    
        
    

        
    
    
    <meta name="HandheldFriendly" content="true"/>
    <meta name="viewport" content="width=device-width, initial-scale=1, user-scalable=no">
    <meta name="apple-mobile-web-app-capable" content="yes">
    <meta name="apple-mobile-web-app-status-bar-style" content="black">
    <link rel="apple-touch-icon-precomposed" sizes="152x152" href="../gitbook/images/apple-touch-icon-precomposed-152.png">
    <link rel="shortcut icon" href="../gitbook/images/favicon.ico" type="image/x-icon">

    
    <link rel="next" href="../Bootstrap/" />
    
    
    <link rel="prev" href="4-Chrome-Developer-Tool.html" />
    

    </head>
    <body>
        
<div class="book">
    <div class="book-summary">
        
            
<div id="book-search-input" role="search">
    <input type="text" placeholder="Type to search" />
</div>

            
                <nav role="navigation">
                


<ul class="summary">
    
    
    
        
        <li>
            <a href="https://girlscodingday.org/" target="_blank" class="custom-link">Girls Coding Day</a>
        </li>
    
    

    
    <li class="divider"></li>
    

    
        
        
    
        <li class="chapter " data-level="1.1" data-path="../">
            
                <a href="../">
            
                    
                    介绍
            
                </a>
            

            
        </li>
    
        <li class="chapter " data-level="1.2" data-path="../Kickoff/">
            
                <a href="../Kickoff/">
            
                    
                    KickOff Party
            
                </a>
            

            
            <ul class="articles">
                
    
        <li class="chapter " data-level="1.2.1" data-path="../Kickoff/1-Teaching-Target.html">
            
                <a href="../Kickoff/1-Teaching-Target.html">
            
                    
                    1.1 教学目的
            
                </a>
            

            
        </li>
    
        <li class="chapter " data-level="1.2.2" data-path="../Kickoff/2-Software-Tool.html">
            
                <a href="../Kickoff/2-Software-Tool.html">
            
                    
                    1.2 软件和工具
            
                </a>
            

            
        </li>
    
        <li class="chapter " data-level="1.2.3" data-path="../Kickoff/3-Learning-Method.html">
            
                <a href="../Kickoff/3-Learning-Method.html">
            
                    
                    1.3 教学方法
            
                </a>
            

            
        </li>
    
        <li class="chapter " data-level="1.2.4" data-path="../Kickoff/4-Web-Basics.html">
            
                <a href="../Kickoff/4-Web-Basics.html">
            
                    
                    1.4 WEB基本知识和历史
            
                </a>
            

            
        </li>
    
        <li class="chapter " data-level="1.2.5" data-path="../Kickoff/5-Pre-Homework.html">
            
                <a href="../Kickoff/5-Pre-Homework.html">
            
                    
                    1.5 课前自学
            
                </a>
            

            
        </li>
    

            </ul>
            
        </li>
    
        <li class="chapter " data-level="1.3" data-path="../HTML/">
            
                <a href="../HTML/">
            
                    
                    Intro to HTML
            
                </a>
            

            
            <ul class="articles">
                
    
        <li class="chapter " data-level="1.3.1" data-path="../HTML/1-HTML-Basics.html">
            
                <a href="../HTML/1-HTML-Basics.html">
            
                    
                    2.1 初识HTML
            
                </a>
            

            
        </li>
    
        <li class="chapter " data-level="1.3.2" data-path="../HTML/2-Common-HTML.html">
            
                <a href="../HTML/2-Common-HTML.html">
            
                    
                    2.2 HTML常用术语
            
                </a>
            

            
        </li>
    
        <li class="chapter " data-level="1.3.3" data-path="../HTML/3-Webpage-Anatomy.html">
            
                <a href="../HTML/3-Webpage-Anatomy.html">
            
                    
                    2.3 解剖网站
            
                </a>
            

            
        </li>
    
        <li class="chapter " data-level="1.3.4" data-path="../HTML/4-Best-Practice.html">
            
                <a href="../HTML/4-Best-Practice.html">
            
                    
                    2.4 动手 - 修改更多HTML
            
                </a>
            

            
        </li>
    

            </ul>
            
        </li>
    
        <li class="chapter " data-level="1.4" data-path="./">
            
                <a href="./">
            
                    
                    Intro to CSS
            
                </a>
            

            
            <ul class="articles">
                
    
        <li class="chapter " data-level="1.4.1" data-path="1-CSS-Basics.html">
            
                <a href="1-CSS-Basics.html">
            
                    
                    3.1 初识CSS
            
                </a>
            

            
        </li>
    
        <li class="chapter " data-level="1.4.2" data-path="2-Common-CSS.html">
            
                <a href="2-Common-CSS.html">
            
                    
                    3.2 CSS常用术语
            
                </a>
            

            
        </li>
    
        <li class="chapter " data-level="1.4.3" data-path="3-Box-Model.html">
            
                <a href="3-Box-Model.html">
            
                    
                    3.3 CSS盒子模型
            
                </a>
            

            
        </li>
    
        <li class="chapter " data-level="1.4.4" data-path="4-Chrome-Developer-Tool.html">
            
                <a href="4-Chrome-Developer-Tool.html">
            
                    
                    3.4 使用Chrome开发者工具调试样式
            
                </a>
            

            
        </li>
    
        <li class="chapter active" data-level="1.4.5" data-path="5-CSS-Best-Practice.html">
            
                <a href="5-CSS-Best-Practice.html">
            
                    
                    3.5 动手 - 修改更多CSS样式
            
                </a>
            

            
        </li>
    

            </ul>
            
        </li>
    
        <li class="chapter " data-level="1.5" data-path="../Bootstrap/">
            
                <a href="../Bootstrap/">
            
                    
                    Intro to Bootstrap
            
                </a>
            

            
            <ul class="articles">
                
    
        <li class="chapter " data-level="1.5.1" data-path="../Bootstrap/1-Grid.html">
            
                <a href="../Bootstrap/1-Grid.html">
            
                    
                    4.1 布局
            
                </a>
            

            
        </li>
    
        <li class="chapter " data-level="1.5.2" data-path="../Bootstrap/2-Bootstrap-CSS.html">
            
                <a href="../Bootstrap/2-Bootstrap-CSS.html">
            
                    
                    4.2 基础Bootstrap CSS
            
                </a>
            

            
        </li>
    
        <li class="chapter " data-level="1.5.3" data-path="../Bootstrap/3-Components.html">
            
                <a href="../Bootstrap/3-Components.html">
            
                    
                    4.3 组件
            
                </a>
            

            
        </li>
    

            </ul>
            
        </li>
    
        <li class="chapter " data-level="1.6" data-path="../Project.html">
            
                <a href="../Project.html">
            
                    
                    大作业
            
                </a>
            

            
        </li>
    
        <li class="chapter " data-level="1.7" data-path="../Share.html">
            
                <a href="../Share.html">
            
                    
                    分享
            
                </a>
            

            
        </li>
    

    

    <li class="divider"></li>

    <li>
        <a href="https://www.gitbook.com" target="blank" class="gitbook-link">
            Published with GitBook
        </a>
    </li>
</ul>


                </nav>
            
        
    </div>

    <div class="book-body">
        
            <div class="body-inner">
                
                    

<div class="book-header" role="navigation">
    

    <!-- Title -->
    <h1>
        <i class="fa fa-circle-o-notch fa-spin"></i>
        <a href=".." >3.5 动手 - 修改更多CSS样式</a>
    </h1>
</div>




                    <div class="page-wrapper" tabindex="-1" role="main">
                        <div class="page-inner">
                            
<div id="book-search-results">
    <div class="search-noresults">
    
                                <section class="normal markdown-section">
                                
                                <h2 id="&#x52A8;&#x624B;---&#x4FEE;&#x6539;&#x66F4;&#x591A;css&#x6837;&#x5F0F;">&#x52A8;&#x624B; - &#x4FEE;&#x6539;&#x66F4;&#x591A;CSS&#x6837;&#x5F0F;</h2>
<ol>
<li><p>&#x5728; css &#x6587;&#x4EF6;&#x5939;&#x4E2D;&#x6DFB;&#x52A0;&#x4E00;&#x4E2A;&#x65B0;&#x6587;&#x4EF6; <code>custom.css</code>,  &#x5E76;&#x5728; index.html &#x6587;&#x4EF6;&#x4E2D;&#x7684;<head>&#x5143;&#x7D20;&#x5F15;&#x7528;&#xFF0C;&#x5982;&#x4E0B;&#x56FE;</head></p>
<p><img src="http://wy.codingirlsclub.com/blog/2017-06-17-013128.jpg" alt=""></p>
</li>
<li><p>&#x4F7F;&#x7528; <em>&#x7C7B;&#x9009;&#x62E9;&#x5668;</em>&#x3001; <em>id&#x9009;&#x62E9;&#x5668;</em> &#x3001; <em>&#x6D3E;&#x751F;&#x9009;&#x62E9;&#x5668;</em>  &#x7ED9; <code>index.html</code> &#x4E2D;&#x7684;&#x5143;&#x7D20;&#x6DFB;&#x52A0;&#x6837;&#x5F0F;&#x3002;<br><strong>&#x89C2;&#x5BDF; index.html&#x4E2D;&#x7684;&#x6587;&#x7AE0;&#x9884;&#x89C8;&#x5143;&#x7D20;(&#x4EC5;&#x622A;&#x53D6;<code>&lt;div class=&quot;post-preview&quot;&gt;</code>&#x6807;&#x7B7E;&#x4E2D;&#x7684;&#x5185;&#x5BB9;)&#xFF1A;</strong></p>
<pre><code class="lang-html"> <span class="hljs-tag">&lt;<span class="hljs-name">div</span> <span class="hljs-attr">class</span>=<span class="hljs-string">&quot;post-preview&quot;</span>&gt;</span>
     <span class="hljs-tag">&lt;<span class="hljs-name">a</span> <span class="hljs-attr">href</span>=<span class="hljs-string">&quot;post.html&quot;</span>&gt;</span>
         <span class="hljs-tag">&lt;<span class="hljs-name">h2</span> <span class="hljs-attr">class</span>=<span class="hljs-string">&quot;post-title&quot;</span>&gt;</span>
             Man must explore, and this is exploration at its greatest
         <span class="hljs-tag">&lt;/<span class="hljs-name">h2</span>&gt;</span>
         <span class="hljs-tag">&lt;<span class="hljs-name">h3</span> <span class="hljs-attr">class</span>=<span class="hljs-string">&quot;post-subtitle&quot;</span>&gt;</span>
             Problems look mighty small from 150 miles up
         <span class="hljs-tag">&lt;/<span class="hljs-name">h3</span>&gt;</span>
     <span class="hljs-tag">&lt;/<span class="hljs-name">a</span>&gt;</span>
     <span class="hljs-tag">&lt;<span class="hljs-name">p</span> <span class="hljs-attr">class</span>=<span class="hljs-string">&quot;post-meta&quot;</span>&gt;</span>Posted by <span class="hljs-tag">&lt;<span class="hljs-name">a</span> <span class="hljs-attr">href</span>=<span class="hljs-string">&quot;#&quot;</span>&gt;</span>Start Bootstrap<span class="hljs-tag">&lt;/<span class="hljs-name">a</span>&gt;</span> on September 24, 2014<span class="hljs-tag">&lt;/<span class="hljs-name">p</span>&gt;</span>
 <span class="hljs-tag">&lt;/<span class="hljs-name">div</span>&gt;</span>
</code></pre>
<ul>
<li>&#x628A; <code>&lt;div class=&quot;post-preview&quot;&gt;</code>&#x6539;&#x4E3A;    <code>&lt;div class=&quot;container&quot; id=&quot;post&quot;&gt;</code></li>
<li><p>&#x8BF7;&#x5728; <code>custom.css</code>&#x4E2D;&#x6DFB;&#x52A0;&#x4E0B;&#x5217;&#x5185;&#x5BB9;&#x5E76;&#x4FDD;&#x5B58;&#xFF0C;<strong>&#x7136;&#x540E;&#x6211;&#x4EEC;&#x6765;&#x770B;&#x770B;CSS&#x4E2D;&#x5982;&#x4F55;&#x4F7F;&#x7528;&#x9009;&#x62E9;&#x5668;&#xFF08;&#x6CE8;&#x610F;&#x9605;&#x8BFB;&#x6CE8;&#x91CA;&#x5185;&#x5BB9;&#xFF09;&#xFF1A;</strong></p>
<pre><code class="lang-css"><span class="hljs-comment">/*&#x8FD9;&#x91CC;&#x7684;&#x201C;*&#x201D;&#x662F;&#x901A;&#x914D;&#x7B26;&#xFF0C;&#x610F;&#x601D;&#x662F;&#x8BE5;&#x9875;&#x9762;&#x4E2D;&#x6240;&#x6709;&#x7684;&#x5143;&#x7D20;&#x90FD;&#x4F1A;&#x88AB;&#x52A0;&#x4E0A;*&#x540E;&#x9762;&#x5927;&#x62EC;&#x53F7;&#x91CC;&#x7684;&#x6837;&#x5F0F;&#xFF0C;
&#x5BF9;&#x5E94;&#x56FE;&#x4E2D;&#x9875;&#x9762;&#x4E2D;&#x6240;&#x6709;&#x7684;&#x6807;&#x7B7E;&#x90FD;&#x6709;&#x7EA2;&#x8272;&#x7684;&#x4E0A;&#x8FB9;&#x6846;*/</span>
*{
  <span class="hljs-attribute">border</span>:<span class="hljs-number">1px</span> solid red;
}
<span class="hljs-comment">/*&#x7C7B;&#x9009;&#x62E9;&#x5668;&#xFF1A;&#x8FD9;&#x91CC;&#x4F7F;&#x7528;.post-title&#x7684;&#x65B9;&#x5F0F;&#x9009;&#x4E2D;&#x6240;&#x6709;&#x5177;&#x6709;&#x7C7B;&#x540D;&#x4E3A;post-title&#x7684;&#x5143;&#x7D20;&#xFF0C;&#x8FD9;&#x91CC;&#x7684;&#x6837;&#x5F0F;&#x4F7F;&#x4ED6;&#x4EEC;&#x5927;&#x5C0F;&#x4E00;&#x6837;&#xFF0C;&#x90FD;&#x6709;&#x7EFF;&#x8272;&#x7684;&#x8FB9;&#x6846;*/</span>
<span class="hljs-selector-class">.post-title</span>{
  <span class="hljs-attribute">background-color</span>: <span class="hljs-number">#777</span>;
  <span class="hljs-attribute">border</span>: <span class="hljs-number">10px</span> solid green;
}

<span class="hljs-comment">/*id&#x9009;&#x62E9;&#x5668;&#xFF1A;&#x8FD9;&#x91CC;&#x4F7F;&#x7528;#post&#x7684;&#x65B9;&#x5F0F;&#x9009;&#x4E2D;&#x5177;&#x6709;id&#x5C5E;&#x6027;&#x503C;&#x4E3A;post&#x7684;&#x5143;&#x7D20;&#xFF0C;&#x6DFB;&#x52A0;&#x6837;&#x5F0F;&#xFF0C;&#x6539;&#x53D8;&#x5B83;&#x7684;&#x80CC;&#x666F;&#x8272;&#x4E3A;&#x767D;&#x8272;, &#x8FB9;&#x6846;&#x4E3A;&#x7EFF;&#x8272;&#x70B9;&#x7EBF;*/</span>
<span class="hljs-selector-id">#post</span>{
  <span class="hljs-attribute">border</span>: <span class="hljs-number">5px</span> dotted green;
  <span class="hljs-attribute">background-color</span>: <span class="hljs-number">#FFF</span>;
}

<span class="hljs-comment">/*&#x6D3E;&#x751F;&#x9009;&#x62E9;&#x5668;&#xFF1A;&#x8FD9;&#x91CC;&#x7684;&#x7A7A;&#x683C;&#x4EE3;&#x8868;&#x5143;&#x7D20;&#x5C42;&#x7EA7;&#x5173;&#x7CFB;&#xFF0C;&#x9009;&#x4E2D;&#x4E86;class&#x5C5E;&#x6027;&#x503C;&#x4E3A;&#x201C;post-meta&#x201D;&#x7684;&#x5143;&#x7D20;&#x5305;&#x542B;&#x94FE;&#x63A5;&#x7684;&#x5143;&#x7D20;&#xFF0C;&#x4F7F;&#x7528;&#x6D3E;&#x751F;&#x9009;&#x62E9;&#x5668;&#x4F1A;&#x4F7F;&#x5F97;&#x4F60;&#x7684;css&#x4EE3;&#x7801;&#x5C42;&#x6B21;&#x66F4;&#x6E05;&#x6670;&#xFF0C;&#x66F4;&#x6709;&#x53EF;&#x8BFB;&#x6027;&#x201D;*/</span>
<span class="hljs-selector-class">.post-meta</span> <span class="hljs-selector-tag">a</span> {
  <span class="hljs-attribute">background-color</span>: blue
}
</code></pre>
</li>
</ul>
</li>
<li>&#x81EA;&#x5DF1;&#x7EC3;&#x4E60;&#x66F4;&#x591A;CSS&#x5C5E;&#x6027;</li>
</ol>

                                
                                </section>
                            
    </div>
    <div class="search-results">
        <div class="has-results">
            
            <h1 class="search-results-title"><span class='search-results-count'></span> results matching "<span class='search-query'></span>"</h1>
            <ul class="search-results-list"></ul>
            
        </div>
        <div class="no-results">
            
            <h1 class="search-results-title">No results matching "<span class='search-query'></span>"</h1>
            
        </div>
    </div>
</div>

                        </div>
                    </div>
                
            </div>

            
                
                <a href="4-Chrome-Developer-Tool.html" class="navigation navigation-prev " aria-label="Previous page: 3.4 使用Chrome开发者工具调试样式">
                    <i class="fa fa-angle-left"></i>
                </a>
                
                
                <a href="../Bootstrap/" class="navigation navigation-next " aria-label="Next page: Intro to Bootstrap">
                    <i class="fa fa-angle-right"></i>
                </a>
                
            
        
    </div>

    <script>
        var gitbook = gitbook || [];
        gitbook.push(function() {
            gitbook.page.hasChanged({"page":{"title":"3.5 动手 - 修改更多CSS样式","level":"1.4.5","depth":2,"next":{"title":"Intro to Bootstrap","level":"1.5","depth":1,"path":"Bootstrap/README.md","ref":"Bootstrap/README.md","articles":[{"title":"4.1 布局","level":"1.5.1","depth":2,"path":"Bootstrap/1-Grid.md","ref":"Bootstrap/1-Grid.md","articles":[]},{"title":"4.2 基础Bootstrap CSS","level":"1.5.2","depth":2,"path":"Bootstrap/2-Bootstrap-CSS.md","ref":"Bootstrap/2-Bootstrap-CSS.md","articles":[]},{"title":"4.3 组件","level":"1.5.3","depth":2,"path":"Bootstrap/3-Components.md","ref":"Bootstrap/3-Components.md","articles":[]}]},"previous":{"title":"3.4 使用Chrome开发者工具调试样式","level":"1.4.4","depth":2,"path":"CSS/4-Chrome-Developer-Tool.md","ref":"CSS/4-Chrome-Developer-Tool.md","articles":[]},"dir":"ltr"},"config":{"plugins":["downloadpdf","livereload"],"styles":{"website":"styles/website.css","pdf":"styles/pdf.css","epub":"styles/epub.css","mobi":"styles/mobi.css","ebook":"styles/ebook.css","print":"styles/print.css"},"pluginsConfig":{"disqus":{"shortName":"girlscodingday"},"livereload":{},"search":{},"downloadpdf":{"label":"Download PDF","multilingual":false,"base":"http://pan.baidu.com/s/1i5L60df"},"lunr":{"maxIndexSize":1000000,"ignoreSpecialCharacters":false},"fontsettings":{"theme":"white","family":"sans","size":2},"highlight":{},"sharing":{"qq":true,"all":["weibo","instapaper","linkedin","pocket","instapaper"],"douban":true,"facebook":false,"weibo":true,"instapaper":false,"whatsapp":false,"twitter":false,"messenger":false,"vk":false,"pocket":true,"google":false,"qzone":true,"linkedin":true},"theme-default":{"styles":{"website":"styles/website.css","pdf":"styles/pdf.css","epub":"styles/epub.css","mobi":"styles/mobi.css","ebook":"styles/ebook.css","print":"styles/print.css"},"showLevel":false}},"theme":"default","author":"Yang Wen <wenyang@codingirls.club>","pdf":{"pageBreaksBefore":"/","headerTemplate":null,"paperSize":"a4","margin":{"right":62,"left":62,"top":36,"bottom":36},"fontSize":12,"fontFamily":"Arial","footerTemplate":null,"chapterMark":"pagebreak","pageNumbers":false},"structure":{"langs":"LANGS.md","readme":"README.md","glossary":"GLOSSARY.md","summary":"SUMMARY.md"},"variables":{},"title":"Girls Coding Day Tutorial","links":{"sharing":{"all":null,"facebook":null,"google":null,"twitter":null,"weibo":"http://weibo.com/codingirlsclub","douban":"https://www.douban.com/people/codingirlsclub/"},"sidebar":{"Girls Coding Day":"https://girlscodingday.org/"}},"gitbook":"*","description":"The tutorial is created for Girls Coding Day","extension":null},"file":{"path":"CSS/5-CSS-Best-Practice.md","mtime":"2017-06-30T14:23:47.000Z","type":"markdown"},"gitbook":{"version":"3.2.3","time":"2018-02-12T07:38:59.260Z"},"basePath":"..","book":{"language":""}});
        });
    </script>
</div>

        
    <script src="../gitbook/gitbook.js"></script>
    <script src="../gitbook/theme.js"></script>
    
        
        <script src="../gitbook/gitbook-plugin-downloadpdf/plugin.js"></script>
        
    
        
        <script src="../gitbook/gitbook-plugin-livereload/plugin.js"></script>
        
    
        
        <script src="../gitbook/gitbook-plugin-search/search-engine.js"></script>
        
    
        
        <script src="../gitbook/gitbook-plugin-search/search.js"></script>
        
    
        
        <script src="../gitbook/gitbook-plugin-lunr/lunr.min.js"></script>
        
    
        
        <script src="../gitbook/gitbook-plugin-lunr/search-lunr.js"></script>
        
    
        
        <script src="../gitbook/gitbook-plugin-sharing/buttons.js"></script>
        
    
        
        <script src="../gitbook/gitbook-plugin-fontsettings/fontsettings.js"></script>
        
    

    </body>
</html>

